package com.chen.blue.domain.dto.system;

import com.fasterxml.jackson.annotation.JsonIgnore;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.io.Serializable;

/**
 * Created By CLT On 2024/5/10.
 */
@SuppressWarnings("all")
@Getter
@Setter
@ApiModel("岗位添加参数")
public class PostDto implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 岗位编码
     */
    @Length(max = 64, message = "岗位编码长度不能超过64个字符")
    @NotNull(message = "岗位编码不能为空")
    @NotBlank(message = "岗位编码不能为空")
    @ApiModelProperty(value = "岗位编码", required = true)
    private String code;

    /**
     * 岗位名称
     */
    @Length(max = 50, message = "岗位名称长度不能超过50个字符")
    @NotNull(message = "岗位名称不能为空")
    @NotBlank(message = "岗位名称不能为空")
    @ApiModelProperty(value = "岗位名称", required = true)
    private String name;

    /**
     * 显示顺序
     */
    @NotNull(message = "显示顺序不能为空")
    @ApiModelProperty(value = "显示顺序", required = true)
    private Integer sort;

    /**
     * 状态（1正常 0停用）
     */
    @NotNull(message = "状态不能为空")
    @ApiModelProperty(value = "状态（true正常 false停用）", required = true)
    private Boolean status;

    /**
     * 备注
     */
    @Length(max = 500, message = "备注长度不能超过500个字符")
    @ApiModelProperty(value = "备注")
    private String remark;

    @JsonIgnore
    private String creator;

    @JsonIgnore
    private String updater;

}
